package hu;

import java.util.*;

public class firuit_bin {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int[] fruit = new int[n];
        for (int i = 0; i < n; i++) {
            fruit[i] = sc.nextInt();
        }
        int m = sc.nextInt();
        int[] question = new int[m];
        for (int i = 0; i < m; i++) {
            question[i] = sc.nextInt();
        }
        // 前缀和 + 二分法
        int[] sums = new int[n];
        sums[0] = fruit[0];
        for (int i = 1; i < n; i++) {
            sums[i] = sums[i - 1] + fruit[i];
        }
        //二分寻找每一个水果的位置
        List<Integer> ans = new ArrayList<>();
        f:for (int i = 0; i < m; i++) {
            int l = 0, r = n;
            while(l < r){
                int mid = l + (r - l) / 2;
                if(sums[mid] == question[i]){
                    ans.add(mid + 1);
                    continue f;
                }
                else if(sums[mid] > question[i])
                    r = mid;
                else l = mid + 1;
            }
            ans.add(r + 1);
        }

        for (int i = 0; i < m; i++) {
            System.out.println(ans.get(i));
        }
    }
}
